package com.yhn.init.model.dto.boards;

import lombok.Data;

import javax.validation.constraints.Min;
import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import java.io.Serial;
import java.io.Serializable;

/**
 * 板子信息
 *
 * @author yhnyhn123
 * @TableName boards
 */
@Data
public class BoardsAddRequest implements Serializable {


    @NotNull(message = "订单ID不能为空")
    private Long orderId;
    /**
     * 板子型号
     */
    @NotBlank(message = "板子型号不能为空")
    private String model;

    /**
     * 板子颜色
     */
    @NotBlank(message = "板子颜色不能为空")
    private String color;

    /**
     * 基材
     */
    @NotBlank(message = "基材不能为空")
    private String material;

    /**
     * 规格
     */
    @NotBlank(message = "规格不能为空")
    private String specification;

    /**
     * 数量
     */
    @NotNull(message = "数量不能为空")
    @Min(value = 1, message = "数量必须大于0")
    private Integer quantity;

    @Serial
    private static final long serialVersionUID = 1L;
}
